unit GLGUIExceptions;

interface

uses
  SysUtils;

type
  EGLGUIException = class(Exception);

const
  EStageExeption =
    'An instance of a 2D GUI Stage can be owned only by TGLGUILayer';

function ESkinNotFoundInCollection(AName, ACollectionName: String): String;
function ESkinNotFound(AName: String): String;
function ESymbolNotFoundInFont(ASymbol, AFont: String): EGLGUIException;

implementation

function ESkinNotFoundInCollection(AName, ACollectionName: String): String;
begin
  Result := 'Skin ' + AName + ' not found in ' + ACollectionName;
end;

function ESkinNotFound(AName: String): String;
begin
  Result := 'Skin ' + AName + ' not found';
end;

function ESymbolNotFoundInFont(ASymbol, AFont: String): EGLGUIException;
begin
  Result := EGLGUIException.Create('Symbol "' + ASymbol +
    '" not found in font "' + AFont + '"');
end;

end.
